import request from '../utils/request'

/**
 * 后面的每次请求都是需要携带token的
 */

export const findUserList = (current,size) => {
	return request({
		url: "/user/findUserList",
		method: 'get',
		params: {
			current,
			size
		}
	})
}

/**
 * 后面的每次请求都是需要携带token的
 */
export const findUserPage= (current,size,userVO) => {
  return request({
    url: "/user/findUserPage",
    method: 'post',
    params: {
      current,
      size
    },
    data: userVO
  })
}

export function login(data) {
	return request({
		url: "/user/login",
		method: 'post',
		data: userVO
	})
}

export function getInfo (token) {
	return request({
		url: "/user/info",
		method: 'get',
		params: { token }
	})
}

export function logout () {
	return request({
		url: "/user/logout",
		method: 'post'
	})
}